<template>
  <Mapbox :mapOnLoadCB="mapOnLoadCB"></Mapbox>
</template>

<script>
import {ref} from "vue"
import Mapbox from "@/components/common/Mapbox.component.vue"
import MapboxCommonService from "@/service/map/MapboxCommonService"
import trackCoords from "@/data/trackCoords"

export default {
  name: "AddTrackPlay.component",
  components: {Mapbox},
  setup() {

    let mapStore = ref({});
    let mapOnLoadCB = (map) => {
      mapStore.value = map;
      MapboxCommonService.addTrackPlay(map, trackCoords);
    };

    return {
      mapOnLoadCB
    }
  }
}
</script>

<style scoped>

</style>